import pandas as pd
list = [[110,120,102],[95,110,108],[98,80,100],[112,106,97]]
index = ['王蒙','李珊','赵胜','刘文']
columns = ['语文','数学','英语']
df = pd.DataFrame(list,index,columns)
print('原始数据:\n',df)
#1
df.loc['王琳'] = [90,100,80]
print('增加"王琳"行后的数据:\n',df)
#2
df.insert(2,'政治',[85,88,70,73,77])
print('再增加"政治"列后的数据:\n',df)
#3
df['哇哈哈'] = [14,12,13,14,12]
print('增加"娃哈哈"列后的数据:\n',df)
